package com.wyl.spelAndAop.service.impl;

import com.wyl.spelAndAop.annotation.MyLog;
import com.wyl.spelAndAop.dto.City;
import com.wyl.spelAndAop.dto.Person;
import com.wyl.spelAndAop.service.HelloService;
import org.springframework.stereotype.Service;

/**
 * @author 吴宇亮 on 2023/4/11 10:34
 */
@Service
public class HelloServiceImpl implements HelloService {

    @MyLog(url = "#{#param[0]}", comments = {"#{#result.city.name}", "#{#result.name}", "#{#param[1].name}", "hello123", "#{'123'.concat(#param[1].name)}",})
    @Override
    public Person hello(String hello, Person person) {
        return new Person()
                .setCity(new City().setName("广州"))
                .setName("张三");
    }
}
